<template>
	<view>
		<view v-if="scope.chnlType == 'jddj'" class="flex just-between ht-42">
			<view style="width: 30%;" class="co">商品金额</view>
			<view class="flex-1 text-right">
				<text style="margin-left: 20px;">{{ formatPrice(a.goodsLevelDiscountAmount) }}</text>
			</view>
		</view>
		<view v-if="scope.chnlType != 'jddj'" class="flex just-between ht-42">
			<view class="co-46">原价总额</view>
			<!-- <text>x {{ scope.orderGoodsNum }}</text> -->
			<text>{{ formatPrice(a.originalPrice) }}</text>
		</view>
		<view class="flex just-between ht-42" v-if="scope.chnlType != 'homemall'">
			<view class="co-46">配送费</view>
			<view>{{ formatPrice(a.deliveryAmount) }}</view>
		</view>
		<view class="flex just-between ht-42" v-if="scope.chnlType == 'homemall'">
			<view class="co-46">基础配送费</view>
			<view>{{ formatPrice(a.baseDeliveryAmount) }}</view>
		</view>
		<view v-if="scope.overWeightDeliveryAmount>0 && scope.chnlType == 'homemall'" class="flex just-between ht-42">
			<view class="co-46">超重配送费</view>
			<view>{{ formatPrice(a.overWeightDeliveryAmount) }}</view>
		</view>
		<view v-if="scope.overDistanceDeliveryAmount>0 && scope.chnlType == 'homemall'" class="flex just-between ht-42">
			<view class="co-46">超远配送费</view>
			<view>{{ formatPrice(a.overDistanceDeliveryAmount) }}</view>
		</view>
		<view class="flex just-between ht-42" v-if="scope.pickType == '1'">
			<view class="co-46">自提服务费</view>
			<view>{{ formatPrice(a.selfPickAmount) }}</view>
		</view>
		<view v-if="a.packageAmount > 0" class="flex just-between ht-42">
			<view class="co-46">包装费</view>
			<view>{{ formatPrice(a.packageAmount) }}</view>
		</view>
		<view class="flex just-between ht-42" v-if="a.lunchBoxAmount > 0">
			<view class="co-46">餐盒费</view>
			<view>{{ formatPrice(a.lunchBoxAmount) }}</view>
		</view>
		<view class="flex just-between ht-42" v-if="a.totalDiscountAmount > 0 && scope.chnlType != 'jddj'">
			<view class="flex">
				<view class="co-46">订单优惠</view>
				<!-- <view class="tag" style="margin-left: 4px;">优惠</view> -->
			</view>
			<view class="co-red">{{ formatPrice(a.totalDiscountAmount, true) }}
			</view>
		</view>
		<view class="flex just-between ht-42" v-if="a.orderLevelDiscount > 0 && scope.chnlType == 'jddj'">
			<view class="flex">
				<view class="co-46">商品优惠</view>
				<!-- <view class="tag" style="margin-left: 4px;">优惠</view> -->
			</view>
			<view class="co-red">{{ formatPrice(a.orderLevelDiscount, true) }}
			</view>
		</view>
		<view class="flex just-between ht-42" v-if="a.deliveryDiscount > 0">
			<view class="flex">
				<view class="co-46">配送费优惠</view>
				<!-- <view class="tag" style="margin-left: 4px;">优惠</view> -->
			</view>
			<view class="co-red">{{ formatPrice(a.deliveryDiscount, true) }}
			</view>
		</view>
		<view class="flex just-between ht-42" v-if="a.selfPickDiscountAmount > 0 && scope.pickType == '1'">
			<view class="flex">
				<view class="co-46">自提服务费优惠</view>
				<!-- <view class="tag" style="margin-left: 4px;">优惠</view> -->
			</view>
			<view class="co-red">{{ formatPrice(a.selfPickDiscountAmount, true)
				}}</view>
		</view>
		<view class="flex just-between ht-42" v-if="a.packageDiscount > 0">
			<view class="flex">
				<view class="co-46">包装费优惠</view>
				<!-- <view class="tag" style="margin-left: 4px;">优惠</view> -->
			</view>
			<view class="co-red">{{ formatPrice(a.packageDiscount, true) }}
			</view>
		</view>
		<view class="flex just-between ht-42" v-if="a.lunchBoxDiscount > 0">
			<view class="flex">
				<view class="co-46">餐盒费优惠</view>
				<!-- <view class="tag" style="margin-left: 4px;">优惠</view> -->
			</view>
			<view class="co-red">{{ formatPrice(a.lunchBoxDiscount, true) }}
			</view>
		</view>
		<view v-if="a.platformPointsAmount > 0" class="flex just-between ht-42">
			<view class="flex">
				<view class="co-46">平台积分抵扣</view>
				<!-- <view class="tag" style="margin-left: 4px;">优惠</view> -->
			</view>
			<view class="co-red">{{ formatPrice(a.platformPointsAmount, true) }}
			</view>
		</view>
		<view v-if="!!(a.bcmAfsOrderPayList)" style="border-top: 1rpx solid #E1E1E1;margin-top: 6rpx;padding: 3rpx 0;">
			<view v-for="(f,i) in a.bcmAfsOrderPayList" :key="i">
				<view class="flex just-between" style="line-height:35rpx;font-size: 32rpx;padding: 10rpx 0 0;">
					<view class="">
						{{ f.payName }}
					</view>
					<view class="" style="color: #E43E00;text-align: right;font-weight: bold;">
						{{ formatPrice(f.amount) }}
					</view>
				</view>
			</view>
		</view>
		<view class="flex just-between ht-42" style="margin: 4rpx 0;" v-else>
			<view class="co-00">实际退款</view>
			<view class="co-red" style="font-weight: bold;">{{ formatPrice(a.refundAmount) }}</view>
		</view>
	</view>
</template>

<script>
import { formatPrice } from '../../../../hooks/bcmUseUntils';
export default {
	props: {
		scope: {
			type: Object,
			default: {}
		},
		a: {
			type: Object,
			default: {}
		}
	},
	data() {
		return {
		}
	},
	methods: {
		formatPrice
	}
};
</script>
<style lang="scss" scoped>
@import '@/static/font/enjoyicon/iconfont.css';
@import '../../common/common.css';
</style>